package com.icbc.digitalwallet.common.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @PackgeName: com.icbc.digitalwallet.common.enums
 * @ClassName: TransTypeEnum
 * @Author: tx
 * Date: 2021/7/18 20:15
 * project name: digitalwallet
 * @Version:
 * @Description:
 */
@AllArgsConstructor
@Getter
public enum TransTypeEnum {
    RECHARGE(0,"充值"),
    WITHDRAW(1,"提现"),
    TRANS_IN(2,"转入"),
    TRANS_OUT(3,"转出"),
    ;

    private Integer transType ;
    private String transTypeName;


    public static String getTransTypeName(int transType) {
        for (TransTypeEnum obj : TransTypeEnum.values()) {
            if (transType == obj.getTransType().intValue()) {
                return obj.getTransTypeName();
            }
        }
        return "";
    }
}
